//package com.zhang.auth.service;
//
//import com.zhang.common.core.constant.MsgTemplate;
//import com.zhang.common.core.po.admin.SysLog;
//import com.zhang.common.log.constant.LogConstant;
//import com.zhang.common.log.event.SysLogEvent;
//import com.zhang.common.log.util.SysLogUtils;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.context.ApplicationContext;
//import org.springframework.scheduling.annotation.Async;
//import org.springframework.stereotype.Service;
//
///**
// * @Description
// * @Author zsw
// * @Date 2019/11/15 13:41
// * @Version V1.0
// **/
//@Service
//public class AuthLogService {
//
//
//    @Autowired
//    ApplicationContext applicationContext;
//
//
//    public void saveLoginLog(String msg, int logLevel) {
//
//        SysLog sysLog = SysLogUtils.getSysLog();
//        sysLog.setLogMessage(msg);
//        sysLog.setOperationType(LogConstant.LOG_OPERATION_TYPE_LOGIN);
//        sysLog.setLogLevel(logLevel);
//        sysLog.setServiceId("auth");
//
//        applicationContext.publishEvent(new SysLogEvent(sysLog));
//
//    }
//}